package com.co.search;

import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.util.Date;

/**
 * @author ldl.plus
 * @date 2020年06月30日  10:30
 */

@Document(indexName = "videoinfo", type = "docs")
public class VideoInfo {

    /**
     * av号 主键
     */
    @Id
    @Field(index = true, store = true, type = FieldType.Keyword)
    private String aid;

    /**
     * 视频名称
     */
    @Field(index = true, store = true, type = FieldType.Text, analyzer = "ik_smart")
    private String title;

    /**
     * 视频缩略图地址
     */
    @Field(index = false, store = true, type = FieldType.Text)
    private String image;

    /**
     * 视频真实url
     */
    @Field(index = false, store = true, type = FieldType.Text)
    private String url;

    /**
     * 视频上传时间
     */
    private Date uploadTime;

    /**
     * 视频所属组群(分类id)
     */
    @Field(index = true, store = true, type = FieldType.Text)
    private String categoryId;

    /**
     * 视频总时常
     */
    @Field(index = true, store = true, type = FieldType.Keyword)
    private Integer durations;

    /**
     * 视频审核状态 0为下架inactive 1为上架active 2为删除
     */
    @Field(index = true, store = true, type = FieldType.Keyword)
    private Integer status;

    /**
     * up主关联username
     */
    @Field(index = true, store = true, type = FieldType.Keyword)
    private String username;

    /**
     * 视频简介
     */
    @Field(index = true, store = true, type = FieldType.Text, analyzer = "ik_smart")
    private String comment;

    /**
     * 该视频有多少P
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer videos;

    /**
     * 观看次数
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer view;

    /**
     * 回复
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer reply;

    /**
     * 弹幕数量
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer danmaku;

    /**
     * 收藏数量
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer favorite;

    /**
     * 点赞数量
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer like;

    /**
     * 踩数量（不喜欢）
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer dislike;

    /**
     * 现在排行
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer nowRank;

    /**
     * 历史排行
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer hisRank;

    /**
     * 分享数量
     */
    @Field(index = true, store = true, type = FieldType.Long)
    private Integer share;

    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 更新时间
     */
    private Date updateTime;

    public Integer getView() {
        return view;
    }

    public void setView(Integer view) {
        this.view = view;
    }

    public Integer getReply() {
        return reply;
    }

    public void setReply(Integer reply) {
        this.reply = reply;
    }

    public Integer getDanmaku() {
        return danmaku;
    }

    public void setDanmaku(Integer danmaku) {
        this.danmaku = danmaku;
    }

    public Integer getFavorite() {
        return favorite;
    }

    public void setFavorite(Integer favorite) {
        this.favorite = favorite;
    }

    public Integer getLike() {
        return like;
    }

    public void setLike(Integer like) {
        this.like = like;
    }

    public Integer getDislike() {
        return dislike;
    }

    public void setDislike(Integer dislike) {
        this.dislike = dislike;
    }

    public Integer getNowRank() {
        return nowRank;
    }

    public void setNowRank(Integer nowRank) {
        this.nowRank = nowRank;
    }

    public Integer getHisRank() {
        return hisRank;
    }

    public void setHisRank(Integer hisRank) {
        this.hisRank = hisRank;
    }

    public Integer getShare() {
        return share;
    }

    public void setShare(Integer share) {
        this.share = share;
    }

    public String getAid() {
        return aid;
    }

    public void setAid(String aid) {
        this.aid = aid;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getImage() {
        return image;
    }

    public void setImage(String image) {
        this.image = image;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public Date getUploadTime() {
        return uploadTime;
    }

    public void setUploadTime(Date uploadTime) {
        this.uploadTime = uploadTime;
    }

    public String getCategoryId() {
        return categoryId;
    }

    public void setCategoryId(String categoryId) {
        this.categoryId = categoryId;
    }

    public Integer getDurations() {
        return durations;
    }

    public void setDurations(Integer durations) {
        this.durations = durations;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getComment() {
        return comment;
    }

    public void setComment(String comment) {
        this.comment = comment;
    }

    public Integer getVideos() {
        return videos;
    }

    public void setVideos(Integer videos) {
        this.videos = videos;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }
}

